package com.hyhy.hycloud.uaa.security.exception;

import com.hyhy.hycloud.uaa.UaaErrorDescribable;
import com.hyhy.hycloud.uaa.UaaErrorType;
import org.springframework.security.core.AuthenticationException;

/**
 * 用户登录错误次数超限异常
 *
 * @author Xuegui Yuan
 * @date 2019-02-25
 */
public class LoginFailureLimitException extends AuthenticationException implements UaaErrorDescribable {
    public LoginFailureLimitException() {
        super(UaaErrorType.LOGIN_FAILURE_LIMIT.getMessage());
    }

    public LoginFailureLimitException(String msg) {
        super(msg);
    }

    public LoginFailureLimitException(String msg, Throwable t) {
        super(msg, t);
    }

    @Override
    public UaaErrorType getErrorType() {
        return UaaErrorType.LOGIN_FAILURE_LIMIT;
    }
}
